//
//  TWSDemoViewController.m
//  TWSWeibo
//
//  Created by Twisal on 2016/12/30.
//  Copyright © 2016年 Twisal. All rights reserved.
//

#import "TWSDemoViewController.h"

@interface TWSDemoViewController ()

@end

@implementation TWSDemoViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    [self setupUserView];
    NSString *currentTitle = [NSString stringWithFormat:@"第%zd个", self.navigationController.childViewControllers.count];
    self.title = currentTitle;
}


- (void)setupUserView {
    [super setupUserView];
    
    self.naviItem.rightBarButtonItem = [UIBarButtonItem itemWithTitle:@"下一个" target:self action:@selector(nextVc)];
}

- (void)nextVc {
    TWSDemoViewController *nextVc = [[TWSDemoViewController alloc] init];
    [self.navigationController pushViewController:nextVc animated:YES];
}

@end
